package cz.muni.fi.pa165.rentalofconstructionmachinery.dto;

import cz.muni.fi.pa165.rentalofconstructionmachinery.entity.CustomerType;
import java.util.Objects;

/**
 *
 * @author Adam Zmrzlý
 */
public class CustomerDTO {
    private Long id;
    private String name;
    private CustomerType type;

    public CustomerDTO(Long id, String name, CustomerType type) {
        this.id = id;
        this.name = name;
        this.type = type;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public CustomerType getType() {
        return type;
    }

    public void setType(CustomerType type) {
        this.type = type;
    }

    @Override
    public int hashCode() {
        int hash = 5;
        hash = 67 * hash + Objects.hashCode(this.id);
        return hash;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final CustomerDTO other = (CustomerDTO) obj;
        if (!Objects.equals(this.id, other.id)) {
            return false;
        }
        return true;
    }
}
